﻿// <copyright file="IMapTo.cs" company="DataAbstractor">
//   (c) Luke Geraghty 2013
// </copyright>
// <summary>
//   Interface mapping for the source class property.
// </summary>

namespace DataAbstractor
{
    using System;
    using System.Linq.Expressions;

    /// <summary>
    /// Interface mapping for the source class property.
    /// </summary>
    /// <typeparam name="TDestination">The destination class.</typeparam>
    /// <typeparam name="TSource">The source class.</typeparam>
    public interface IMapTo<TDestination, TSource>
    {
        /// <summary>
        /// Map the destination property to a value.
        /// </summary>
        /// <param name="value">The value to map the property to.</param>
        /// <returns>The destination mapping class.</returns>
        IMapFrom<TDestination, TSource> Value(object value);

        /// <summary>
        /// Map the destination property to a value in the source class.
        /// </summary>
        /// <param name="source">The source property.</param>
        /// <returns>The destination mapping class.</returns>
        IMapFrom<TDestination, TSource> To(Expression<Func<TSource, object>> source);
    }
}
